<%@ tag language="java" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<c:set var="pathinfo" value="${fn:split(pageContext.request.requestURI, '/')}" />
<c:set var="path" value="${pathinfo[2]}" />
<c:set var="file" value="${pathinfo[fn:length(pathinfo) - 1]}" />

		<div class="accordion" id="leftMenu">
			<div class="accordion-group">
				<div class="accordion-heading ${empty path ? 'active-accordion-page' : '' }">
					<a class="accordion-toggle"
						data-parent="#leftMenu" href="."> <i class="icon-home icon-wierd-grey"></i> Home
					</a>
				</div>
			</div>
			
			<div class="accordion-group">
				<div class="accordion-heading ${path eq 'consultar' ? 'active-accordion-page' : '' }">
					<a class="accordion-toggle"
						data-parent="#leftMenu" href="./view/consultar/index.jsp"> <i
						class="icon-search icon-purple"></i> Consultar
					</a>
				</div>
			</div>
			
			<c:if test="${not empty funcionario_session.login}">
				<div class="accordion-group">
					<div class="accordion-heading ${path eq 'produtos' ? 'active-accordion-page' : '' }">
						<a class="accordion-toggle" data-toggle="collapse"
							data-parent="#leftMenu" href="#collapseTwo"> <i class="icon-book icon-blue"></i> Produtos
						</a>
					</div>
					<div id="collapseTwo" class="accordion-body collapse"
						style="height: 0px;">
						<div class="accordion-inner">
							<ul class="icons-ul">
								<li class="alert-over li-minus-margin ${path eq 'produtos' and file eq 'adicionar.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/produtos/adicionar.jsp"><i class="icon-plus icon-black"></i>  Adicionar</a></li>
								<li class="alert-over li-minus-margin ${path eq 'produtos' and file eq 'visualizar.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/produtos/visualizar.jsp"><i class="icon-eye-open icon-black"></i> Visualizar</a></li>
							</ul>
						</div>
					</div>
				</div>
				<div class="accordion-group">
					<div class="accordion-heading ${path eq 'clientes' ? 'active-accordion-page' : '' }">
						<a class="accordion-toggle" data-toggle="collapse"
							data-parent="#leftMenu" href="#collapseThree"> <i
							class="icon-group icon-brown"></i> Clientes
						</a>
					</div>
					<div id="collapseThree" class="accordion-body collapse"
						style="height: 0px;">
						<div class="accordion-inner">
							<ul class="icons-ul">
								<li class="alert-over li-minus-margin ${path eq 'clientes' and file eq 'adicionar.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/clientes/adicionar.jsp"><i class="icon-plus icon-black"></i>  Adicionar</a></li>
								<li class="alert-over li-minus-margin ${path eq 'clientes' and file eq 'visualizar.do' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/clientes/visualizar.do"><i class="icon-eye-open icon-black"></i> Visualizar</a></li>
							</ul>
						</div>
					</div>
				</div>
				<div class="accordion-group">
					<div class="accordion-heading ${path eq 'funcionarios' ? 'active-accordion-page' : '' }">
						<a class="accordion-toggle" data-toggle="collapse"
							data-parent="#leftMenu" href="#collapseFour"> <i
							class="icon-user icon-green"></i> Funcionários
						</a>
					</div>
					<div id="collapseFour" class="accordion-body collapse"
						style="height: 0px;">
						<div class="accordion-inner">
							<ul class="icons-ul">
								<li class="alert-over li-minus-margin ${path eq 'funcionarios' and file eq 'adicionar.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/funcionarios/adicionar.jsp"><i class="icon-plus icon-black"></i>  Adicionar</a></li>
								<li class="alert-over li-minus-margin ${path eq 'funcionarios' and file eq 'visualizar.do' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/funcionarios/visualizar.do"><i class="icon-eye-open icon-black"></i> Visualizar</a></li>
							</ul>
						</div>
					</div>
				</div>
				<div class="accordion-group">
					<div class="accordion-heading ${path eq 'vendas' ? 'active-accordion-page' : '' }">
						<a class="accordion-toggle" data-toggle="collapse"
							data-parent="#leftMenu" href="#collapseFive"> <i
							class="icon-star icon-yellow"></i> Vendas
						</a>
					</div>
					<div id="collapseFive" class="accordion-body collapse"
						style="height: 0px;">
						<div class="accordion-inner">
							<ul class="icons-ul">
								<li class="alert-over li-minus-margin ${path eq 'vendas' and file eq 'vender.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/vendas/vender.jsp"><i class="icon-exchange icon-black"></i>  Vender</a></li>
								<li class="alert-over li-minus-margin ${path eq 'vendas' and file eq 'visualizar.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/vendas/visualizar.jsp"><i class="icon-eye-open icon-black"></i> Visualizar</a></li>
							</ul>
						</div>
					</div>
				</div>
				<div class="accordion-group">
					<div class="accordion-heading ${path eq 'opcoes' ? 'active-accordion-page' : '' }">
						<a class="accordion-toggle" data-toggle="collapse"
							data-parent="#leftMenu" href="#collapseSix"> <i
							class="icon-heart icon-red"></i> Minhas opções
						</a>
					</div>
					<div id="collapseSix" class="accordion-body collapse"
						style="height: 0px;">
						<div class="accordion-inner">
							<ul class="icons-ul">
								<li class="alert-over li-minus-margin ${path eq 'opcoes' and file eq 'editar_informacoes.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/opcoes/editar_informacoes.jsp"><i class="icon-edit icon-black"></i>  Editar Informações</a></li>
								<li class="alert-over li-minus-margin ${path eq 'opcoes' and file eq 'editar_senha.jsp' ? 'alert alert-active' : 'alert alert-none' }"><a href="./view/opcoes/editar_senha.jsp"><i class="icon-key icon-black"></i> Editar Senha</a></li>
							</ul>
						</div>
					</div>
				</div>
				
				<div class="accordion-group">
					<div class="accordion-heading">
						<a class="accordion-toggle confirm"
							data-parent="#leftMenu" href="./view/logout.do"> <i
							class="icon-exclamation-sign icon-black"></i> Logout
						</a>
					</div>
				</div>
			</c:if>
			
		</div>